﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using EntityFrameworks.Data.Core;
using System.Data.Entity;
using EntityFrameworks.Entity.Core;
using IRepository.Core;

namespace Common.Background
{

    public class BackgroundBase<TEntity> : DbContextRepository<TEntity> where TEntity : class
    {
        #region Constructors

        public BackgroundBase()
            : this(null) { }

        public BackgroundBase(IUnitOfWork iUnitWork)
            : this(iUnitWork, null) { }

        public BackgroundBase(IUnitOfWork iUnitWork, Action<string> logDelegate)
            : base((backgroundEntities)iUnitWork ?? new backgroundEntities(), logDelegate)
        { }

        #endregion
    }
}